export function getToken() {
    return localStorage.getItem("token");
}
export function getUserInfo() {
    console.log( JSON.parse(localStorage.getItem("userInfo")))
    return JSON.parse(localStorage.getItem("userInfo"));
}
    


export function setToken(token) {
    localStorage.setItem("token", token);
}
export function setUserInfo(userInfo) {
    localStorage.setItem("userInfo", JSON.stringify(userInfo));
}

export function removeToken() {
    localStorage.removeItem("token");
}
export function removeUserInfo() {
    localStorage.removeItem("userInfo");
}
export function removeUser() {
    localStorage.removeItem("user");
}